<extend name="Public:base"/>

<block name="main">
<div id="yzh-content" class="col-xs-12">
    <div class="main-title">
        <h2>首页广告</h2>
    </div>

    <div class="table-actions">
        <a class="btn btn-sm btn-primary" onclick="myform.action='{:U('wap/slidesort')}';$('#myform').submit();">排序</a>
        <a href="{:U('wap/addslide')}" class="btn btn-sm btn-primary env-class">新增</a>
    </div>

    <form name="myform" id="myform" action="" method="post">
        <table class="table table-bordered table-hover">
            <thead>
                <tr>
                    <th width="48">排序</th>
                    <th>缩略图</th>
                    <th width="140" class="center">管理操作</th>
                </tr>
            </thead>
            <tbody>
                <volist name="list" id="vo" key="k">
                <tr>
                    <td width="40" class='center'>
                        <input name='sort[{$vo.id}]' type='text' size='3' value='{$vo.sort}' class='form-control'>
                    </td>
                    <td align="left">
                        <img src="{$vo['pic']|thumb=###,'160'}">
                    </td>
                    <td class="center">
                        <a class="btn btn-primary btn-xs" href="{:U('Wap/editslide',array('id'=>$vo['id']))}">修改</a>
                    </td>
                </tr>
                </volist>
            </tbody>
        </table>
    </form>
</div>

</block>